// 公共css放这里
// mixin 详见 ../mixins/index.scss
// reset样式
// @include oReset();
// fs 12 to 64px; eg: fs-12 fs-16
@include oFsSet(26);
@include oPdMgSet(12, 10);
@include oPdMgSet(16, 4);
// rate:15 rotate 0 to 360 eg: rot-90
@include oRotate();
// flex相关
@include oFlex();
// 超过n行后显示... eg:text-line-1 2 3
@include oTextLine(3);
@include oBorder1px(#ececec);
html {
  /* prettier-ignore */
  font-size: 16PX;
}
pre {
  white-space: pre-wrap;
}
// 点击背景
body {
  -webkit-tap-highlight-color: transparent;
  /* px-to-viewport-ignore-next */
  font-size: 12px; /* px-to-viewport-ignore */
}
.f-l {
  float: left;
}
.f-r {
  float: right;
}
// 清除浮动
.c-b {
  @include iCB();
}
.show {
  display: block;
}
.hide {
  display: none;
}
.hide-v {
  visibility: hidden;
}
// display
.d-i {
  display: inline;
}
.d-i-b {
  display: inline-block;
}
.d-b {
  display: block;
}
// vertical-align
.va-m {
  vertical-align: middle;
}
.va-t {
  vertical-align: top;
}
.va-b {
  vertical-align: bottom;
}
// overflow
%of-a,
.of-a {
  overflow: auto;
  // 移动端
  -webkit-overflow-scrolling: touch;
}
.of-s {
  overflow: scroll;
}
.of-h {
  overflow: hidden;
}

.page {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  overflow: hidden;
}

// 白色背景
%bg-w,
.bg-w {
  background-color: #fff;
}
.bg-w-full {
  @extend %bg-w;
  &::before {
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    bottom: 0;
    z-index: -1;
    @extend %bg-w;
    content: '';
  }
}
%bg-grey,
.bg-grey {
  background-color: $grey-lighter;
}
.bg-grey-full {
  @extend %bg-grey;
  &::before {
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    bottom: 0;
    z-index: -1;
    @extend %bg-grey;
    content: '';
  }
}
// 宽度100%
.full-w {
  width: 100%;
}

// 高度100%
.full-h {
  height: 100%;
}

// 对齐方式
.ta-c {
  text-align: center;
}
.ta-l {
  text-align: left;
}
.ta-r {
  text-align: right;
}
// 禁用状态
.disabled {
  position: relative;
  &::after {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    right: 0;
    background-color: rgba(184, 190, 196, 0.2);
    color: #fff;
  }
}

// 圆
.round {
  border-radius: 1000px;
}

// 换行
%w-b,
.w-b {
  word-wrap: break-word;
}
input,
textarea {
  @extend %w-b;
}

// position
.p-r {
  position: relative;
}
.p-a {
  position: absolute;
}
.p-f {
  position: fixed;
}

// 加粗
.b {
  font-weight: bold;
}

// 点击效果
.tap {
  transition: 400ms;
  &:active {
    transition: 0;
    background-color: #d9d9d9;
  }
}
// 清除btn样式
.btn-none {
  margin: 0;
  padding: 0;
  line-height: unset;
  text-align: unset;
  border-radius: 0;
  background-color: transparent;
  border: none;
  @include iFlex(flex-middle);
  &.button-hover {
    color: unset;
    background-color: transparent;
  }
  &::after {
    border: none;
  }
}

// uniui
.uni-section__content {
  display: flex;
}
// checkbox选中样式
uni-checkbox:not([disabled]) .uni-checkbox-input:hover {
  border-color: c(theme);
}
uni-checkbox .uni-checkbox-input.uni-checkbox-input-checked {
  color: c(theme);
  border-color: c(theme);
}
// h5下,image标签自适应
/*  #ifdef  H5  */
image {
  width: auto;
  height: auto;
  max-width: 100%;
  object-fit: cover;
  img {
    position: relative;
    opacity: 1;
    object-fit: cover;
  }
}
/*  #endif  */
